<!DOCTYPE html>
<html class="writer-html5" lang="en" >
<head>
  <meta charset="utf-8" /><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" />

  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  <title>Developer &mdash; Zapmenot 0.1 documentation</title>
      <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
      <link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
  <!--[if lt IE 9]>
    <script src="_static/js/html5shiv.min.js"></script>
  <![endif]-->
  
        <script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script>
        <script src="_static/jquery.js"></script>
        <script src="_static/underscore.js"></script>
        <script src="_static/_sphinx_javascript_frameworks_compat.js"></script>
        <script src="_static/doctools.js"></script>
        <script src="_static/sphinx_highlight.js"></script>
    <script src="_static/js/theme.js"></script>
    <link rel="index" title="Index" href="genindex.html" />
    <link rel="search" title="Search" href="search.html" />
    <link rel="next" title="Version History" href="version-history.html" />
    <link rel="prev" title="Module Contents" href="module-docs.html" /> 
</head>

<body class="wy-body-for-nav"> 
  <div class="wy-grid-for-nav">
    <nav data-toggle="wy-nav-shift" class="wy-nav-side">
      <div class="wy-side-scroll">
        <div class="wy-side-nav-search" >
            <a href="index.html" class="icon icon-home"> Zapmenot
          </a>
              <div class="version">
                0.1
              </div>
<div role="search">
  <form id="rtd-search-form" class="wy-form" action="search.html" method="get">
    <input type="text" name="q" placeholder="Search docs" />
    <input type="hidden" name="check_keywords" value="yes" />
    <input type="hidden" name="area" value="default" />
  </form>
</div>
        </div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
              <ul class="current">
<li class="toctree-l1"><a class="reference internal" href="license.html">Licence &amp; Disclaimer</a></li>
<li class="toctree-l1"><a class="reference internal" href="getting-started.html">Getting Started</a></li>
<li class="toctree-l1"><a class="reference internal" href="materials.html">Material Library</a></li>
<li class="toctree-l1"><a class="reference internal" href="isotopes.html">Isotope Library</a></li>
<li class="toctree-l1"><a class="reference internal" href="modeling.html">Modeling in ZapMeNot</a></li>
<li class="toctree-l1"><a class="reference internal" href="results.html">Generating Results</a></li>
<li class="toctree-l1"><a class="reference internal" href="graphics.html">We Want Pictures!</a></li>
<li class="toctree-l1"><a class="reference internal" href="theory-and-methods.html">Theory and Methods</a></li>
<li class="toctree-l1"><a class="reference internal" href="benchmarks.html">Benchmarking</a></li>
<li class="toctree-l1"><a class="reference internal" href="module-docs.html">Module Contents</a></li>
<li class="toctree-l1 current"><a class="current reference internal" href="#">Developer</a><ul>
<li class="toctree-l2"><a class="reference internal" href="#testing">Testing</a></li>
<li class="toctree-l2"><a class="reference internal" href="#unit-tests">Unit Tests</a></li>
<li class="toctree-l2"><a class="reference internal" href="#benchmark-tests">Benchmark Tests</a></li>
<li class="toctree-l2"><a class="reference internal" href="#graphics-tests">Graphics Tests</a></li>
<li class="toctree-l2"><a class="reference internal" href="#coverage">Coverage</a></li>
<li class="toctree-l2"><a class="reference internal" href="#updating-a-version">Updating A Version</a></li>
<li class="toctree-l2"><a class="reference internal" href="#updating-copyright">Updating Copyright</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="version-history.html">Version History</a></li>
</ul>

        </div>
      </div>
    </nav>

    <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
          <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
          <a href="index.html">Zapmenot</a>
      </nav>

      <div class="wy-nav-content">
        <div class="rst-content">
          <div role="navigation" aria-label="Page navigation">
  <ul class="wy-breadcrumbs">
      <li><a href="index.html" class="icon icon-home"></a></li>
      <li class="breadcrumb-item active">Developer</li>
      <li class="wy-breadcrumbs-aside">
            <a href="_sources/developer.rst.txt" rel="nofollow"> View page source</a>
      </li>
  </ul>
  <hr/>
</div>
          <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
           <div itemprop="articleBody">
             
  <section id="developer">
<h1>Developer<a class="headerlink" href="#developer" title="Permalink to this heading"></a></h1>
<section id="testing">
<h2>Testing<a class="headerlink" href="#testing" title="Permalink to this heading"></a></h2>
<p>Test cases packaged with ZapMeNot fall into three categories;
unit tests, graphics tests, and benchmarks.</p>
</section>
<section id="unit-tests">
<h2>Unit Tests<a class="headerlink" href="#unit-tests" title="Permalink to this heading"></a></h2>
<p>These tests are verify that code blocks are functioning as
intended.  To execute the unit tests, use the following code:</p>
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">cd ZapMeNot</span>
<span class="go">pytest -m basic</span>
</pre></div>
</div>
</section>
<section id="benchmark-tests">
<h2>Benchmark Tests<a class="headerlink" href="#benchmark-tests" title="Permalink to this heading"></a></h2>
<p>The benchmarks are not designed to identify errors in ZapMeNot, but
rather to examine the accuracy of the calculations.  The following
code block can be used to execute the benchmarks.  Note the use of the
“-s” option, which ensures that normal console output is retained by
the testing routines.</p>
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">cd ZapMeNot</span>
<span class="go">pytest -s -m benchmark</span>
</pre></div>
</div>
</section>
<section id="graphics-tests">
<h2>Graphics Tests<a class="headerlink" href="#graphics-tests" title="Permalink to this heading"></a></h2>
<p>The graphics tests can be used to verify that the ZapMeNot display
functions are performing as expected.  Some of these test cases will
generate a display of a ZapMeNot geometry; these can be used to verify
that geometries are properly displayed.  Other test cases are used
to trap expected errors.</p>
<p>Note that the graphics tests cases as currently configured will fail
when run on a “headless” server, i.e. a server without graphics hardware.</p>
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">cd ZapMeNot</span>
<span class="go">pytest -m graphics</span>
</pre></div>
</div>
</section>
<section id="coverage">
<h2>Coverage<a class="headerlink" href="#coverage" title="Permalink to this heading"></a></h2>
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">cd ZapMeNot/coverage</span>
<span class="go">./runCoverage.sh</span>
</pre></div>
</div>
</section>
<section id="updating-a-version">
<h2>Updating A Version<a class="headerlink" href="#updating-a-version" title="Permalink to this heading"></a></h2>
<p>Following successful testing, the following steps are used to generate a new version of ZapMeNot:</p>
<ul class="simple">
<li><p>Update the version number in ZapMeNot/zapmenot/__about__.py</p></li>
<li><p>Optionally update the interSphinx input by executing <code class="code docutils literal notranslate"><span class="pre">update.sh</span></code> from the ZapMeNot/docsrc/interSphinx folder</p></li>
<li><p>Rebuild the documentation by executing <code class="code docutils literal notranslate"><span class="pre">make</span> <span class="pre">html</span></code> from the ZapMeNot/docsrc folder</p></li>
<li><p>Build the distribution packages by executing <code class="code docutils literal notranslate"><span class="pre">python</span> <span class="pre">-m</span> <span class="pre">build</span></code> from the ZapMeNot folder</p></li>
</ul>
</section>
<section id="updating-copyright">
<h2>Updating Copyright<a class="headerlink" href="#updating-copyright" title="Permalink to this heading"></a></h2>
<p>Update the year in the following files:</p>
<ul class="simple">
<li><p><cite>ZapMeNot/docsrc/source/license.rst</cite></p></li>
<li><p><cite>ZapMeNot/zapmenot/__about__.py</cite></p></li>
</ul>
</section>
</section>


           </div>
          </div>
          <footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
        <a href="module-docs.html" class="btn btn-neutral float-left" title="Module Contents" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
        <a href="version-history.html" class="btn btn-neutral float-right" title="Version History" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
    </div>

  <hr/>

  <div role="contentinfo">
    <p>&#169; Copyright 2019 - 2023, Alan Ford..
      <span class="lastupdated">Last updated on Feb 12, 2023.
      </span></p>
  </div>

  Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
    <a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
    provided by <a href="https://readthedocs.org">Read the Docs</a>.
   

</footer>
        </div>
      </div>
    </section>
  </div>
  <script>
      jQuery(function () {
          SphinxRtdTheme.Navigation.enable(true);
      });
  </script> 

</body>
</html>